package io.mft.commons.multithreading.worker;

import org.slf4j.Logger;
import org.slf4j.LoggerFactory;

public class WorkRunner implements Runnable{
	static Logger logger=LoggerFactory.getLogger(WorkRunner.class);
	private Work work;
	private WorkManager workManager;
	public WorkRunner(Work work,WorkManager workManager) {
		this.work=work;
		this.workManager=workManager;
	}
	@Override
	public void run() {
		try {
			work.handle();
		} catch (Exception e) {
			logger.error("",e);
		}finally {
			//workManager.decrease();
		}
		
	}

}
